package com.cloudkinto.service.stock;

import com.baomidou.mybatisplus.extension.service.IService;
import com.cloudkinto.common.web.PageResult;
import com.cloudkinto.common.web.SingleResult;
import com.cloudkinto.dto.stock.StockCheckPageDto;
import com.cloudkinto.dto.stock.query.SkuCellStockPageDto;
import com.cloudkinto.entity.StockCheckDo;
import com.cloudkinto.service.stock.vo.snap.StockCheckAddReq;
import com.cloudkinto.service.stock.vo.snap.StockCheckUpdateReq;

import javax.servlet.http.HttpServletResponse;
import java.util.List;
import java.util.Map;

/**
 * <p>
 * service接口
 * </p>
 *
 * @author hua
 * @since 2024-12-23
 */
public interface StockCheckService extends IService<StockCheckDo> {

    List<SkuCellStockPageDto> productListPageByLocation(Map<String, Object> map);

    SingleResult addInit();

    Object add(StockCheckAddReq req, Long userId, Long whId, Long tenantId);


    void start(Long id, Long userId, Long whId, Long tenantId);


    void submit(Long id, Long userId, Long whId, Long tenantId);

    void abort(Long id, Long userId, Long whId, Long tenantId);

    Object update(StockCheckUpdateReq updateVo, Long userId, Long whId, Long tenantId);

    int delete(Long id, Long userId);

    Object detail(Long id, Long whId, Long tenantId);

    SingleResult pageInit();

    List<StockCheckPageDto> getList(Map<String, Object> map);

    PageResult getListPage(Map<String, Object> map);

    List<Map<String, Object>> statusStatistics(Map<String, Object> map);

    void printCheckList(Map<String, Object> map, HttpServletResponse response) throws Exception;

}
